﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="OrdenVentaEditForm.aspx.cs" 
Inherits="UILGestion.VentaAdmin.OrdenVenta.OrdenVentaEditForm" %>

<%@ Register Assembly="WebLib" Namespace="WebLib" TagPrefix="lib" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
<%@ Register src="../../Control/menuCtrl.ascx" tagname="menuCtrl" tagprefix="uc1" %>



<%@ Register src="OrdenVentaItem.ascx" tagname="OrdenVentaItem" tagprefix="uc2" %>


<xml:namespace ns="urn:schemas-microsoft-com:vml" prefix="v" />

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <link href="../../css/main.css" rel="stylesheet" type="text/css" />
 <link rel="stylesheet" type="text/css" href="../../estilos/_common/styles/fonts.css" />
 <link rel="stylesheet" type="text/css" href="../../estilos/_common/styles/global.css" />
 <link rel="stylesheet" type="text/css" href="../../estilos/_common/styles/theme.css" />
 <style type="text/css">

table {border-collapse:collapse}
#dispo td{
	border:thin solid #007FFF;
	height: 20px;
	text-align: center;
}
#leyenda td{
	border:thin solid #007FFF;
}

</style>
    <title>EDITAR ORDEN VENTA</title>
    <script src="../../Scripts/OrdenVenta.js" type="text/javascript"></script>
    <script src="../../Scripts/SearchResult.js" type="text/javascript"></script>

    <script src="../../Scripts/jquery-1.5.2.min.js" type="text/javascript"></script>
   <script type="text/javascript">
       $(document).ready(function () {
           $(document).bind('contextmenu', function (e) {
               return false;
           });
       });



</script>


   
  
   
   
    </head>
<body>
    <form id="form1" runat="server">
    <input id="type" type="hidden" runat="server" />
    <input id="internalID" type="hidden" runat="server" />
  
    <input id="paginaAnt" type="hidden" runat="server" />
        <input id="idProforma" type="hidden" runat="server" />
    <input id="idColeccion" type="hidden" runat="server" />
   
    <input id="idProyecto" type="hidden" runat="server" />
     <uc1:menuCtrl ID="menuCtrl1" runat="server" />
    
      <asp:ToolkitScriptManager ID="ToolkitScriptManager2" runat="server" 
      EnableScriptGlobalization="true"  
     EnablePartialRendering="true" />
    
     <asp:Panel ID="pnlMain" runat="server"
  CssClass="Heading secTitle AreaHeading ms-crm-List-Header">
  <asp:Label ID="Label2" runat="server" Text="EDITAR ORDEN VENTA" 
             style="font-size: large; color: #960818"></asp:Label>
 </asp:Panel>

          <asp:Panel ID="PanelButtom" runat="server"     class="ms-crm-Form-Body" >                 
   <table >
<tr>

<td>
    <asp:Button ID="saveBTN" runat="server" Text="Guardar"   OnClientClick="return confirm('Usted quiere guardar la Orden Venta?')"   
       OnClick="button"   CssClass="ms-crm-List-Header"    /></td>
<td>
    <asp:Button ID="cancelarBTN" runat="server" Text="Cancelar"  
       OnClick="button" CssClass="ms-crm-List-Header"  /></td>
        <td></td>
        <td>
    <asp:Button ID="refreshBTN" runat="server" Text="Restablecer"   OnClick="button" CssClass="ms-crm-List-Header" 
          /></td> 
 
</tr>
</table>
</asp:Panel>

<asp:Panel ID="PanelBody" runat="server"  BackColor="white" >



                
                <table>
                   
                    <tr>
                        <td rowspan="11" valign="top"  >
               
                                     <table>
                                         <tr>
                                             <td align="right" width="100px">
                                                 Num. Documento:</td>
                                             <td width="280px">
                                                
                                                 <asp:Label ID="numDocumento" runat="server" Text=""></asp:Label>
                                             </td>
                                         </tr>
                                         <tr>
                                             <td align="right" width="100px">
                                                 Fecha:</td>
                                             <td width="280px">
                                                 <asp:TextBox ID="fechaTXT" runat="server" Width="70px" TabIndex="1"></asp:TextBox>
                                                 <asp:ImageButton ID="ImageButton3" runat="Server" 
                                                     AlternateText="Click aqui para mostrar calendario" 
                                                     ImageUrl="~/Images/month.gif" Width="16px" />
                                                 <asp:CalendarExtender ID="CalendarExtender2" runat="server" 
                                                     PopupButtonID="ImageButton3" TargetControlID="FechaTXT">
                                                 </asp:CalendarExtender>
                                             </td>
                                         </tr>
                                         <tr>
                                             <td align="right" width="100px">
                                                 Propietario: </td>
                                             <td width="280px">
                                                 <lib:Input ID="clienteTXT" runat="server" DataType="List"  backcolor="#DFE8F6"  method="GetCliente" 
                                                     NumColum="2" onchange="javascript:validarCliente(this);" 
                                                     OnSelect="SelectCliente" Width="250px" TabIndex="2"></lib:Input>
                                                 <lib:Input ID="cliente1TXT" runat="server" BackColor="Transparent" 
                                                     ReadOnly="true" Width="0px"></lib:Input>
                                                 <lib:Input ID="idClienteTXT" runat="server" BackColor="Transparent" 
                                                     ReadOnly="true" Width="0px"></lib:Input>
                                                 
                                                 </td>
                                         </tr>
                                         <tr>
                                             <td align="right" width="100px" valign="bottom">
           Co Propietario:<asp:CheckBox ID="copropietarioCHK" runat="server" AutoPostBack="true" 
                                                     oncheckedchanged="copropietarioCHK_CheckedChanged" TabIndex="3" /></td>
                                             <td width="280px">

               <asp:UpdatePanel ID="copropietarioUPNL" runat="server" UpdateMode="Conditional">
                                        <ContentTemplate>
                                        
                                            <asp:Panel ID="copropietarioPNL" runat="server" >
               

                                                 <lib:Input ID="coclienteTXT" runat="server" DataType="List" 
                                                     method="GetCliente"   backcolor="#DFE8F6" 
                                                     NumColum="2" onchange="javascript:validarCliente2(this);" 
                                                     OnSelect="SelectCliente2" Width="250px" TabIndex="4"></lib:Input>
                                                 <lib:Input ID="coClienteTXT1" runat="server" BackColor="Transparent" 
                                                     ReadOnly="true" Width="0px"></lib:Input>
                                                 <lib:Input ID="idCoClienteTXT" runat="server" BackColor="Transparent" 
                                                     ReadOnly="true" Width="0px"></lib:Input>
                                                 
                                                 </asp:Panel>
                                                 </ContentTemplate>
                                                 <Triggers>
                                                 <asp:AsyncPostBackTrigger ControlID="copropietarioCHK" />
                                                 </Triggers>
                                        </asp:UpdatePanel>

                                             </td>
                                         </tr>
                                         <tr>
                                             <td align="right" width="100px">
                                                 Formato Venta:</td>
                                             <td width="280px">
                                                 <asp:DropDownList ID="formatoVentaDDL" runat="server"  AutoPostBack="true"
                                                     onselectedindexchanged="formatoVentaDDL_SelectedIndexChanged" 
                                                     Width="250px" TabIndex="5">
                                                 </asp:DropDownList>
                                             </td>
                                         </tr>
                                 <tr>
                                <td align="right" width="100px">
                                    &nbsp;</td>
                                <td width="280px" >
                                    <asp:UpdatePanel ID="bancoUPNL" runat="server" UpdateMode="Conditional">
                                        <ContentTemplate>
                                            <asp:Panel ID="bancoPNL" runat="server">
                                                <table>
                                                    <tr>
                                                        <td width="60px" align="right">
                                                            Banco:</td>
                                                        <td>
                                                            <asp:DropDownList ID="bancoDDL" runat="server" Width="180px" TabIndex="6">
                                                            </asp:DropDownList>
                                                        </td>
                                                    </tr>
                                                    <tr>
                                                        <td>
                                                            &nbsp;</td>
                                                        <td>
                                                            Es Cuenta Ahorro?:<asp:CheckBox ID="cuentaAhorroCHK" ToolTip="Si el Cliente  depositará en una cuenta del Banco  4 o 6 meses para su calificación  " runat="server" TabIndex="7" />
                                                        </td>
                                                    </tr>
                                                </table>
                                            </asp:Panel>
                                        </ContentTemplate>
                                        <Triggers>
                                        <asp:AsyncPostBackTrigger  ControlID="formatoVentaDDL"/>
                                        </Triggers>
                                    </asp:UpdatePanel>
                                     </td>
                            </tr>
                           
                        </table>
               
                        </td>
                    </tr>
                  
               
                    <tr >
                        <td style="text-align: right" valign="top">
                       
                            Vendedor:</td>
                        <td valign="top">
                            <asp:Label ID="vendedorLBL" runat="server"></asp:Label>
                        </td>
                        <td align="right" rowspan="5" width="180px">
                            <asp:UpdatePanel ID="totalUPNL" runat="server" UpdateMode="Conditional">
                                <ContentTemplate>
                                    <table>
                                        <tr>
                                            <td colspan="3">
                                                &nbsp;</td>
                                        </tr>
                                        <tr>
                                            <td>
                                                <table class="PanelTotales">
                                                    <tr>
                                                        <td align="right">
                                                            Total:</td>
                                                        <td align="right" width="120px">
                                                            <asp:Label ID="totalLabel" runat="server"></asp:Label>
                                                        </td>
                                                    </tr>
                                                    <tr>
                                                        <td align="right">
                                                            &nbsp;</td>
                                                        <td align="right" valign="100px">
                                                            <br />
                                                        </td>
                                                    </tr>
                                                    <tr>
                                                        <td align="right">
                                                            &nbsp;</td>
                                                        <td align="right" valign="100px">
                                                            &nbsp;</td>
                                                    </tr>
                                                </table>
                                            </td>
                                        </tr>
                                    </table>
                                </ContentTemplate>
                            </asp:UpdatePanel>
                        </td>
                        <td>
                            &nbsp;</td>
                    </tr>
                    <tr >
                        <td align="right" valign="top" width="130px">
                            Comentario:</td>
                        <td>
                            <asp:TextBox ID="comentarioTXT" runat="server" Height="70px" 
                                TextMode="MultiLine" Width="200px" TabIndex="8"></asp:TextBox>
                        </td>
                        <td>
                          
                            &nbsp;</td>
                    </tr>
                    <tr>
                        <td align="right" valign="top" width="130px">
                            Moneda:</td>
                        <td>
                            <asp:DropDownList ID="monedaDDL" runat="server" Enabled="false" Width="150px">
                            </asp:DropDownList>
                        </td>
                        <td>
                            &nbsp;</td>
                    </tr>
                    <tr>
                        <td align="right" valign="top" width="130px">
                            &nbsp;</td>
                        <td>
                            &nbsp;</td>
                        <td>
                            &nbsp;</td>
                    </tr>
                    <tr>
                        <td align="right" valign="top" width="130px">
                            &nbsp;</td>
                        <td>
                            &nbsp;</td>
                        <td>
                            &nbsp;</td>
                    </tr>
                    <tr>
                        <td>
                            &nbsp;</td>
                        <td>
                            &nbsp;</td>
                    </tr>
                </table>
            
 
  
      <asp:TabContainer ID="TabContainer1" runat="server"  ActiveTabIndex="0"  
          Width="100%" >
          <asp:TabPanel ID="TabPanel1" runat="server" HeaderText="Detalle" >
          <ContentTemplate>
<asp:UpdatePanel ID="itemUpdatePanel" runat="server" UpdateMode="Conditional">
<ContentTemplate>
        <uc2:OrdenVentaItem ID="OrdenVentaItem1" runat="server" />
</ContentTemplate>
</asp:UpdatePanel>
</ContentTemplate>
</asp:TabPanel></asp:TabContainer>
      
      

 
               
      
      

 
 </asp:Panel>
   
  
   
  
      
    
   
  
   
    </form>
          
    </body>
</html>
